/**
 * Created by Administrator on 2017/6/16.
 */
Zepto(function(){
    //静态资源加载完成loading图片隐藏
    /*setTimeout(function(){
        $('#loading').hide();
    },500);
    //页面显示
    $("body").animate({
        'opacity':1,
       },500,"ease-out")*/
    //首页tab切换事件
    var isActive=true;
    $.each($(".tab_List li"),function(index,item){
        var that=$(this);
       $(item).find("h2").on("click",function(){

           if(isActive){
               isActive=!isActive;
               that.children(".content_detail").css("display","none");
            }else{
               isActive=!isActive;
               that.addClass("active");
               that.children(".content_detail").css("display","block");
               that.siblings("li").removeClass("active").children(".content_detail").css("display","none");
           }
       })
   });

    //左侧导航
    isToggle=true;
    $("#toggleBar").on("click",function(){
        if(isToggle){
            isToggle=!isToggle;
            $(".crumb").animate({"left":0},500,"linear");
        }else{
            isToggle=!isToggle;
            $(".crumb").animate({"left":"-6rem"},500,"linear");
        }
    })
})